-
Notifications
You must be signed in to change notification settings - Fork 221
[tsp-client] Batch generation #13023
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Relies on #13027 |
…tsp-client/batch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds batch generation support to the tsp-client tool, enabling users to process multiple TypeSpec directories in a single command by defining a batch configuration in the parent tsp-location.yaml file.
- Introduces a new
batchfield toTspLocationinterface for specifying multiple subdirectories - Makes
directory,commit, andrepofields optional inTspLocationto support batch mode - Implements recursive batch processing in
updateCommandthat processes each subdirectory independently
Reviewed changes
Copilot reviewed 16 out of 16 changed files in this pull request and generated 14 comments.
Show a summary per file
| File | Description |
|---|---|
| tools/tsp-client/src/typespec.ts | Modified TspLocation interface to support batch mode by making standard fields optional and adding batch array field |
| tools/tsp-client/src/fs.ts | Updated readTspLocation to validate batch configurations and handle optional directory normalization |
| tools/tsp-client/src/commands.ts | Added processBatchUpdate function and modified updateCommand, syncCommand, and generateCommand to support batch processing |
| tools/tsp-client/src/npm.ts | Added tspClientCommand helper function (currently unused) |
| tools/tsp-client/test/commands.spec.ts | Added tests for batch configuration reading and batch directory processing with/without local spec paths |
| tools/tsp-client/test/examples/batch/**/*.yaml | Added test fixtures for batch configuration including parent and child tsp-location.yaml files |
| tools/tsp-client/test/examples/batch/service/**/*.tsp | Added TypeSpec test fixtures for rbac, settings, and restore services |
| tools/tsp-client/test/examples/batch/service/package.json | Added emitter package configuration for batch test scenarios |
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
…-tools into tsp-client/batch
|
/check-enforcer override |
Fixes #12963